﻿<Grid x:Class="Daytimer.Controls.MonthDetail" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
		xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
		xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
		xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:local="clr-namespace:Daytimer.Controls"
		xmlns:Friction="clr-namespace:Daytimer.Controls.Friction" mc:Ignorable="d" Height="18" d:DesignWidth="100"
		Margin="0,0,10,1" Focusable="False" Background="Transparent">
	<Grid x:Name="display" Height="18" Background="{DynamicResource Appointment}"
			ContextMenuOpening="display_ContextMenuOpening">
		<Grid.ColumnDefinitions>
			<ColumnDefinition Width="Auto" />
			<ColumnDefinition />
		</Grid.ColumnDefinitions>
		<Border x:Name="showAsStrip" Width="7" BorderBrush="{DynamicResource Blue}" BorderThickness="1"
				IsHitTestVisible="False" />
		<Button x:Name="subjectDisplayOuter" Grid.Column="1" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
				Width="NaN" Height="NaN" MinWidth="0" Focusable="False" Foreground="#FF3C3C3C"
				Click="subjectDisplayOuter_Click" MouseDoubleClick="subjectDisplayOuter_MouseDoubleClick">
			<Button.Template>
				<ControlTemplate TargetType="Button">
					<Border Background="Transparent">
						<ContentPresenter IsHitTestVisible="False" />
					</Border>
				</ControlTemplate>
			</Button.Template>
			<Grid>
				<Grid.ColumnDefinitions>
					<ColumnDefinition Width="*" />
					<ColumnDefinition Width="Auto" />
				</Grid.ColumnDefinitions>
				<TextBlock x:Name="subjectDisplay" TextWrapping="NoWrap" FontSize="11" TextTrimming="CharacterEllipsis"
						Padding="2,0,2,1" VerticalAlignment="Center" />
				<Image x:Name="recurrenceIcon" Grid.Column="1" Stretch="None" HorizontalAlignment="Center"
						VerticalAlignment="Center" Margin="4,0"
						Source="pack://application:,,,/Daytimer.Images;component/Images/recurrence_sml2.png" />
			</Grid>
		</Button>
		<Grid.ContextMenu>
			<ContextMenu>
				<MenuItem x:Name="openMenuItem" Header="_Open">
					<MenuItem.Icon>
						<Image Source="pack://application:,,,/Daytimer.Images;component/Images/open_sml.png" />
					</MenuItem.Icon>
					<MenuItem Header="Open _Occurrence" Click="openOccurrence_Click" />
					<MenuItem Header="Open _Series" Click="openSeries_Click" />
				</MenuItem>
				<MenuItem x:Name="exportMenuItem" Header="_Export" Click="exportMenuItem_Click">
					<MenuItem.Icon>
						<Image Source="pack://application:,,,/Daytimer.Images;component/Images/export_sml.png" />
					</MenuItem.Icon>
				</MenuItem>
				<MenuItem x:Name="directionsMenuItem" Header="Get _Directions" Visibility="Collapsed" IsEnabled="False"
						Click="directionsMenuItem_Click">
					<MenuItem.Icon>
						<Image Source="pack://application:,,,/Daytimer.Images;component/Images/maplocation.png" />
					</MenuItem.Icon>
				</MenuItem>
				<Separator />
				<MenuItem x:Name="privateMenuItem" Header="Pri_vate" IsCheckable="True" Click="privateMenuItem_Click">
					<MenuItem.Icon>
						<Image Source="pack://application:,,,/Daytimer.Images;component/Images/lock_sml.png" />
					</MenuItem.Icon>
				</MenuItem>
				<MenuItem x:Name="showAsMenuItem" Header="_Show As">
					<MenuItem.Icon>
						<Image Source="pack://application:,,,/Daytimer.Images;component/Images/showas.png" />
					</MenuItem.Icon>
					<MenuItem Header="_Free" IsCheckable="True" Click="free_Click">
						<MenuItem.Icon>
							<Border Width="12" Height="12" BorderBrush="{DynamicResource Blue}" BorderThickness="1"
									Background="{DynamicResource FreeFill}" />
						</MenuItem.Icon>
					</MenuItem>
					<MenuItem Header="_Working Elsewhere" IsCheckable="True" Click="workingElsewhere_Click">
						<MenuItem.Icon>
							<Border Width="12" Height="12" BorderBrush="{DynamicResource Blue}" BorderThickness="1"
									Background="{DynamicResource WorkingElsewhereFill}" />
						</MenuItem.Icon>
					</MenuItem>
					<MenuItem Header="_Tentative" IsCheckable="True" Click="tentative_Click">
						<MenuItem.Icon>
							<Border Width="12" Height="12" BorderBrush="{DynamicResource Blue}" BorderThickness="1"
									Background="{DynamicResource TentativeFill}" />
						</MenuItem.Icon>
					</MenuItem>
					<MenuItem Header="_Busy" IsCheckable="True" Click="busy_Click">
						<MenuItem.Icon>
							<Border Width="12" Height="12" BorderBrush="{DynamicResource Blue}" BorderThickness="1"
									Background="{DynamicResource BusyFill}" />
						</MenuItem.Icon>
					</MenuItem>
					<MenuItem Header="_Out of Office" IsCheckable="True" Click="outOfOffice_Click">
						<MenuItem.Icon>
							<Border Width="12" Height="12" BorderBrush="{DynamicResource Blue}" BorderThickness="1"
									Background="{DynamicResource OutOfOfficeFill}" />
						</MenuItem.Icon>
					</MenuItem>
				</MenuItem>
				<MenuItem x:Name="recurrenceMenuItem" Header="_Recurrence">
					<MenuItem.Icon>
						<Image Source="pack://application:,,,/Daytimer.Images;component/Images/recurrence_sml.png" />
					</MenuItem.Icon>
					<MenuItem Header="_Previous Occurrence" Click="previousOccurrence_Click" />
					<MenuItem Header="_Next Occurrence" Click="nextOccurrence_Click" />
				</MenuItem>
				<Separator />
				<MenuItem x:Name="deleteMenuItem" Header="_Delete" Click="deleteMenuItem_Click">
					<MenuItem.Icon>
						<Image Source="pack://application:,,,/Daytimer.Images;component/Images/delete_sml.png" />
					</MenuItem.Icon>
				</MenuItem>
				<MenuItem x:Name="deleteRecurrenceMenuItem" Header="_Delete">
					<MenuItem.Icon>
						<Image Source="pack://application:,,,/Daytimer.Images;component/Images/delete_sml.png" />
					</MenuItem.Icon>
					<MenuItem Header="_Occurrence" Click="deleteOccurrence_Click" />
					<MenuItem Header="_Series" Click="deleteSeries_Click" />
				</MenuItem>
			</ContextMenu>
		</Grid.ContextMenu>
	</Grid>
	<Grid x:Name="edit" Visibility="Collapsed" IsEnabled="False" Margin="5,-5,-5,5">
		<Grid.RowDefinitions>
			<RowDefinition Height="Auto" />
			<RowDefinition Height="*" />
		</Grid.RowDefinitions>
		<Button x:Name="cancelEditButton" Click="cancelEditButton_Click" Height="16" Width="16"
				HorizontalAlignment="Right" Margin="0,3,-2,2" MinWidth="0" ClickMode="Release" Focusable="False">
			<Button.Template>
				<ControlTemplate TargetType="ButtonBase">
					<Border Background="Transparent" SnapsToDevicePixels="True">
						<Path x:Name="content" Stroke="Black" StrokeThickness="2"
								Data="M 0.5 0.5 7.75 7.75 M 0.5 7.5 7.75 0.25" HorizontalAlignment="Center"
								VerticalAlignment="Center" IsHitTestVisible="False" RenderOptions.EdgeMode="Aliased" />
					</Border>
					<ControlTemplate.Triggers>
						<Trigger Property="IsMouseOver" Value="True">
							<Setter Property="Stroke" TargetName="content" Value="#FF444444" />
						</Trigger>
						<Trigger Property="IsPressed" Value="True">
							<Setter Property="Stroke" TargetName="content"
									Value="{DynamicResource SmallDetailClosePressed}" />
						</Trigger>
					</ControlTemplate.Triggers>
				</ControlTemplate>
			</Button.Template>
		</Button>
		<Friction:FrictionTextBox x:Name="subjectEdit" Grid.Row="1" BorderThickness="0" TextWrapping="Wrap"
				FontSize="11" SpellCheck.IsEnabled="True" VerticalContentAlignment="Top" KeyDown="subjectEdit_KeyDown"
				Padding="1,3,1,2" SelectionBrush="#FF909090" GotKeyboardFocus="subjectEdit_GotKeyboardFocus" />
	</Grid>
</Grid>
